{% extends "Common/AdminBase.html" %}
{% load filters %} 
{% block Location %}

<li class="current" ><a href='/AdminMain/Article/Index/'>文章列表</a></li>
<li>/</li>
<li class="current">普通文章发布</li>
<script>
Nav_Page="Article";
</script>

{% endblock %}


{% block content %}

		<link rel="stylesheet" href="/site_media/admin/kindeditor/themes/default/default.css" />
		<script charset="utf-8" src="/site_media/admin/kindeditor/kindeditor-min.js"></script>
		<script charset="utf-8" src="/site_media/admin/kindeditor/lang/zh_CN.js"></script>
<script type='text/javascript' src='/site_media/admin/My97DatePicker/WdatePicker.js'></script>

<div class="contentcontainer">
	
	<form action="#" AjaxForm="/AdminMain/Article/DoAddCommon/" Ajaxverify="$.AjaxFormVerify"    AjaxSuccess="onRefresh">
		<input type="hidden" id="ContentId" name="ContentId" value="{{Model.ContentId}}">
            {% include 'AdminMain/Article/ContentBase.html' %}
     <br/>
	      <div class="headings alt">
                <h2>扩展信息</h2>
            </div>
            <div class="contentbox">
            	
				  <div style="width:100%;float:left">
					<p style="float:left;width:350px">
                        <label for="textfield"><strong>作者</strong></label>
                        <input id="Author" maxlength="20"  name="Author" type="text"  maxlength="100" class="inputbox"> 
						<br>
                    </p>
                   
					<p style="float:left;">
                        <label  for="textfield"><strong>来源</strong></label>
                        <input id="Source" maxlength="20"  name="Source" type="text"  maxlength="100" class="inputbox"> 
						<br>
                    </p>
				</div>
				
				
					
				<div style="width:100%;float:left">
					<p style="float:left;">
                        <label for="textfield"><strong>内容</strong></label>
						
						<textarea name="content" id="content" style="width:680px;height:350px;visibility:hidden;"></textarea>
						<br>
                    </p>
				</div>
				
				
				<div style="width:100%;float:left">
					<p style="float:left;">
							 <input type="submit"  value="发表" onclick=“saveOut()” class="btn"> 
							 <input type="submit"  value="发表并继续" onclick=“saveIn()” class="btn">
							 <input type="submit"  value="保存到草稿" onclick=“savecg()” class="btn">
                    </p>
				</div>
				<input type="hidden" name="State" id="State" value="1">
	   </div>
	   
	 </form>
        </div>
		

<script>
	var outlocd="";
	
function saveOut()
{
	$("#State").val("1");
	outlocd="/AdminMain/Article/Index/"
}

function saveIn()
{
	$("#State").val("1");
	outlocd=window.location;
}

function savecg()
{
	$("#State").val("4");
	outlocd="/AdminMain/Article/Index/"
}

function OnChange()
{
	
}
	
	
var editor;
KindEditor.ready(function(K) {
	editor = K.create('textarea[name="content"]', {
	uploadJson: '/AdminMain/SysFile/UpFile/?ModelId={{Model.ContentId}}',
	allowFileManager : false
	});
});



function onRefresh(obj)
{
	$.tips(obj.ErrorTxt);
	window.location=outlocd;
}
</script>
          
    
		
{% endblock %}

